package io.geekidea.boot.shop.service.base.api;

import com.baomidou.mybatisplus.extension.service.IService;
import io.geekidea.boot.framework.page.Paging;
import io.geekidea.boot.shop.dto.BackDto;
import io.geekidea.boot.shop.entity.Back;
import io.geekidea.boot.shop.query.app.AppBackQuery;
import io.geekidea.boot.shop.query.web.BackQuery;
import io.geekidea.boot.shop.vo.app.AppBackVo;
import io.geekidea.boot.shop.vo.web.BackVo;


/**
 * 服务接口
 *
 * @author geekidea
 * @since 2024-10-27
 */
public interface BackService extends IService<Back> {

    /**
     * 添加
     *
     * @param dto
     * @return
     * @throws Exception
     */
    boolean addBack(BackDto dto);

    /**
     * 修改
     *
     * @param dto
     * @return
     * @throws Exception
     */
    boolean updateBack(BackDto dto);

    /**
     * 删除
     *
     * @param id
     * @return
     * @throws Exception
     */
    boolean deleteBack(Integer id);

    /**
     * 详情
     *
     * @param id
     * @return
     * @throws Exception
     */
    BackVo getBackById(Integer id);

    /**
     * 分页列表
     *
     * @param query
     * @return
     * @throws Exception
     */
    Paging<BackVo> getBackPage(BackQuery query);

    /**
     * Appnull详情
     *
     * @param id
     * @return
     * @throws Exception
     */
    AppBackVo getAppBackById(Integer id);

    /**
     * Appnull分页列表
     *
     * @param query
     * @return
     * @throws Exception
     */
    Paging<AppBackVo> getAppBackPage(AppBackQuery query);

}
